<?php

namespace common\models\base;

use Yii;

/**
 * This is the model class for table "{{%unionpay_3002_set_log}}".
 *
 * @property int $id
 * @property string $order_id
 * @property string $u_name
 * @property string $id_card
 * @property string $p_data
 * @property int $p_at
 * @property string $r_data
 * @property int $r_at
 * @property double $score
 * @property int $last_get_time
 * @property string $device_name 机型
 * @property string $status_message
 */
class Unionpay3002SetLog extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return '{{%unionpay_3002_set_log}}';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['order_id'], 'required'],
            [['p_data', 'r_data'], 'string'],
            [['p_at', 'r_at', 'last_get_time'], 'integer'],
            [['score'], 'number'],
            [['order_id'], 'string', 'max' => 50],
            [['u_name', 'id_card', 'device_name'], 'string', 'max' => 20],
            [['status_message'], 'string', 'max' => 200],
            [['order_id'], 'unique'],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => Yii::t('app', 'ID'),
            'order_id' => Yii::t('app', 'Order ID'),
            'u_name' => Yii::t('app', 'U Name'),
            'id_card' => Yii::t('app', 'Id Card'),
            'p_data' => Yii::t('app', 'P Data'),
            'p_at' => Yii::t('app', 'P At'),
            'r_data' => Yii::t('app', 'R Data'),
            'r_at' => Yii::t('app', 'R At'),
            'score' => Yii::t('app', 'Score'),
            'last_get_time' => Yii::t('app', 'Last Get Time'),
            'device_name' => Yii::t('app', '机型'),
            'status_message' => Yii::t('app', 'Status Message'),
        ];
    }
}
